perm filename ACCENT.MF[CM,DEK]3 blob sn#796683 filedate 1985-06-22 generic text, type C, neo UTF8
COMMENT āŠ—   VALID 00015 PAGES
C REC  PAGE   DESCRIPTION
C00001 00001
C00003 00002	% This file contains accents common to text roman and italic fonts.
C00004 00003	cmchar "Grave accent"
C00005 00004	cmchar "Acute accent"
C00007 00005	cmchar "Hachek (check) accent"
C00009 00006	cmchar "Breve accent"
C00010 00007	cmchar "Macron (bar) accent"
C00011 00008	cmchar "Scandinavian circle accent"
C00013 00009	cmchar "Cedilla accent"
C00015 00010	iff ligs>0: cmchar "Cross for Polish l and L"
C00017 00011	cmchar "Circumflex (hat) accent"
C00019 00012	iff ligs>0: cmchar "Dot accent"
C00020 00013	iff ligs>0: cmchar "Long Hungarian umlaut accent"
C00022 00014	cmchar "Tilde (squiggle) accent"
C00024 00015	cmchar "Umlaut (double dot) accent"
C00026 ENDMK
CāŠ—;
% This file contains accents common to text roman and italic fonts.
% Character codes \0022--\0030, \0040, \0136--\0137, \0175--\0177 are generated.

% (Actually the accents in positions \0040, \0137, and \0175 are
% not generated unless |ligs>0|, since other symbols are substituted
% for those accents in non-ligature fonts.)
cmchar "Grave accent";
beginchar(oct"022",9u#,min(asc_height#,2x_height#),0); less_rounded;
adjust_fit(0,0);
if serifs: pickup crisp.nib; x1-.5stem=round 2u; x2=2/3[x1,w-x1];
 y1+.5stem=h; y2=max(2/3[h,x_height],x_height+o+hair);
 numeric theta; theta=angle(z2-z1)+90;
 pos1(stem,theta); pos2(hair,theta);
 filldraw z1l---z2l--z2r---z1r..cycle;	% diagonal
else: pickup fine.nib; pos1(stem,0); pos2(vair,0);
 lft x1l=round 1.5u; rt x2r=round(.5w+.25u+.5vair);
 top y1=h; bot y2=round(2/3[h,x_height]);
 filldraw stroke z1e..z2e; fi	% diagonal
penlabels(1,2); endchar;
cmchar "Acute accent";
beginchar(oct"023",9u#,min(asc_height#,2x_height#),0); less_rounded;
italcorr h#*slant-if serifs: 1.5 fi u#;
adjust_fit(0,0);
if serifs: pickup crisp.nib; x1+.5stem=round(w-2u); x2=2/3[x1,w-x1];
 y1+.5stem=h; y2=max(2/3[h,x_height],x_height+o+hair);
 numeric theta; theta=angle(z2-z1)+90;
 pos1(stem,theta); pos2(hair,theta);
 filldraw z1l---z2l--z2r---z1r..cycle;	% diagonal
else: pickup fine.nib; pos1(stem,0); pos2(vair,0);
 rt x1r=round(w-1.5u); lft x2l=round(.5w-.25u-.5vair);
 top y1=h; bot y2=round(2/3[h,x_height]);
 filldraw stroke z1e..z2e; fi	% diagonal
penlabels(1,2); endchar;
cmchar "Hachek (check) accent";
beginchar(oct"024",9u#,.75[x_height#,min(asc_height#,2x_height#)],0);
less_rounded;
h':=round min(asc_height,2x_height); % height of circumflex being inverted
if serifs: italcorr h#*slant+.5hair#-1.75u#;
 adjust_fit(0,0);
 pickup crisp.nib; pos2'(.5[vair,curve],90); top y2'r=h;
 pos2(.5[vair,curve],90); x2=.5w;
 x1=w-x3=2.25u; top y1=top y3=h; y1-y2=.5(y2'-x_height);
 pos1(hair,angle(z2-z1)+90); pos3(hair,angle(z3-z2)+90);
 filldraw stroke z1e--z2e--z3e;	% diagonals
else: italcorr h#*slant-.5stem#+.5vair#-.75u#;
 adjust_fit(0,0);
 pickup fine.nib; pos1(vair,0); pos3(vair,0); x1=w-x3;
 pos2(stem,0); bot y2=round(1/12[x_height,h']+o); x2=.5w;
 top y1=top y3=h+o; lft x1l=round(rt x2r-3.25u-.5vair);
 z0=whatever[z1r,z2r]=whatever[z2l,z3l];
 y4l=y4r=y2; x4l=good.x(.2[x2l,x2]); x4r=w-x4l;
 filldraw z4l--z1l--z1r--z0--z3l--z3r--z4r--cycle; fi	% diagonals
penlabels(0,1,2,3,4); endchar;
cmchar "Breve accent";
beginchar(oct"025",9u#,min(asc_height#,2x_height#),0);
italcorr h#*slant+.5vair#-1.5u#;
adjust_fit(0,0);
pickup crisp.nib; pos1(vair,-180); pos3(vair,0);
top y1=top y3=h; lft x1r=w-rt x3r=round(2u-.5vair);
numeric mid_thickness; mid_thickness=round(1/3[vair,stem]);
pos2(mid_thickness,-90); x2=.5w;
bot y2r=round max(x_height+o+tiny,1/3[x_height,h]+o-.5mid_thickness);
filldraw stroke z1e{down}...z2e{right}...{up}z3e;	% stroke
penlabels(1,2,3); endchar;
cmchar "Macron (bar) accent";
numeric macron_breadth#; macron_breadth#=.2[vair#,stem#];
beginchar(oct"026",9u#,.4[x_height#,asc_height#]+macron_breadth#,0);
less_rounded;
italcorr h#*slant-.75u#;
adjust_fit(0,0);
numeric macron_breadth; macron_breadth:=round(.2[vair,stem]);
pickup if serifs: crisp.nib else: fine.nib fi;
pos1(macron_breadth,90); pos2(macron_breadth,90);
top y1r=top y2r=h+o; lft x1=w-rt x2=round 1.25u;
filldraw stroke z1e..z2e;	% bar
penlabels(1,2); endchar;
cmchar "Scandinavian circle accent";
beginchar(oct"027",13u#+4/3(asc_height#-x_height#)*slant,asc_height#,0);
adjust_fit(cap_serif_fit#,cap_serif_fit#);
numeric circ_hair,circ_vair;
circ_hair=round min(hair,u+.5); circ_vair=round min(vair,(h-x_height)/6+.5);
if min(circ_hair,circ_vair)=1: less_rounded; fi
penpos1(circ_vair,90); penpos3(circ_vair,-90);
penpos2(circ_hair,180); penpos4(circ_hair,0);
x2r=round(.5w-1.5u-.5circ_hair);
x4r=w-x2r; x1=x3=.5w; y1r=h+apex_o; y2=y4=.5[y1,y3];
y3r=round(1/3[x_height,h]+apex_o);
penstroke pulled_super_arc.e(1,2)(superpull)
 & pulled_super_arc.e(2,3)(superpull)
 & pulled_super_arc.e(3,4)(superpull)
 & pulled_super_arc.e(4,1)(superpull) & cycle;	% bowl
penlabels(1,2,3,4); endchar;
cmchar "Cedilla accent";
beginchar(oct"030",8u#,0,.875desc_depth#);
adjust_fit(0,0);
x1=.5w+.5u;
if serifs: pickup crisp.nib; pos1(stem,0); pos2(stem,0);
 pos3(vair,90); pos4(stem,0); pos5(vair,-90);
 x1=x2; z3l=z2l; x4=x2+1.5u; x5=x3-1.5u;
 bot y1=-o; bot y2=-round 2/7d-o; y4=.5[y3,y5]; bot y5=-d-o;
 filldraw stroke z1e..z2e;	% stem
 filldraw stroke z3e{right}...z4e{down}...{left}z5e;	% hook
else: pickup fine.nib; pos1(vair,0); top y1=-o-2;
 pos2(.5[vair,stem],0); bot y2=-d-o; x2=x1-1.25u;
 filldraw stroke z1e..z2e; fi	% diagonal
penlabels(1,2,3,4,5); endchar;
iff ligs>0: cmchar "Cross for Polish l and L";
if unknown l_width#:
 l_width#:=5u#+2serif_fit#; fi	% nominal width of `l'
if unknown L_stem#:
 L_stem#:=cap_serif_fit#+max(2u#+.5cap_stem#,3u#); fi	% position of `L' stem
ligtable oct"040": "l" kern -l_width#-2letter_fit#,
 "L" kern -.5l_width#-L_stem#-2letter_fit#;
beginchar(oct"040",l_width#,x_height#,0); less_rounded;
adjust_fit(stem_shift#,-stem_shift#);
pickup crisp.nib; x2-x1=max(4u,2.8u+stem); .5[x1,x2]=.5w;
y1-.5bar=.2[bar_height,x_height]; y2+.5bar=.8[bar_height,x_height];
numeric theta; theta=angle(z2-z1)+90;
pos1(bar,theta); pos2(bar,theta);
filldraw stroke z1e..z2e;	% diagonal
penlabels(1,2); endchar;
cmchar "Circumflex (hat) accent";
beginchar(oct"136",9u#,min(asc_height#,2x_height#),0); less_rounded;
if serifs: italcorr .5[x_height#,h#]*slant+.5hair#-1.75u#;
 adjust_fit(0,0);
 pickup crisp.nib; pos2(.5[vair,curve],90); top y2r=h; x2=.5w;
 x1=w-x3=2.25u; y1=y3=.5[x_height,y2];
 pos1(hair,angle(z2-z1)+90); pos3(hair,angle(z3-z2)+90);
 filldraw stroke z1e--z2e--z3e;	% diagonals
else: italcorr 2/3[x_height#,h#]*slant-.5stem#+.5vair#-.75u#;
 adjust_fit(0,0);
 pickup fine.nib; pos1(vair,0); pos3(vair,0); x1=w-x3;
 pos2(stem,0); top y2=h; x2=.5w; bot y1=bot y3=round(2/3[h,x_height]);
 lft x1l=round(rt x2r-3.25u-.5vair); % same slope as in the acute accent
 z0=whatever[z1r,z2r]=whatever[z2l,z3l];
 y4l=y4r=y2; x4l=good.x(.2[x2l,x2]); x4r=w-x4l;
 filldraw z4l--z1l--z1r--z0--z3l--z3r--z4r--cycle; fi	% diagonals
penlabels(0,1,2,3,4); endchar;
iff ligs>0: cmchar "Dot accent";
numeric dot_diam#; dot_diam#=max(dot_size#,cap_curve#);
beginchar(oct"137",5u#,min(asc_height#,10/7x_height#+.5dot_diam#),0);
define_whole_blacker_pixels(dot_diam);
italcorr h#*slant+.5dot_diam#-2u#;
adjust_fit(0,0);
pickup tiny.nib; pos1(dot_diam,0); pos2(dot_diam,90);
x1=x2=.5w; top y2r=h+1;
if bot y2l<x_height+o+slab: y2l:=min(y2r-2epsilon,x_height+o+slab+.5tiny); fi
y1=.5[y2l,y2r]; dot(1,2);	% dot
penlabels(1,2); endchar;
iff ligs>0: cmchar "Long Hungarian umlaut accent";
beginchar(oct"175",9u#,min(asc_height#,2x_height#),0); less_rounded;
italcorr h#*slant-u#;
adjust_fit(0,0);
x3-x1=x4-x2=round 3u; y3=y1; y4=y2;
if serifs: pickup crisp.nib; x3+.5stem=round(w-1.5u); x2=2.5u;
 y1+.5stem=h; y2=max(2/3[h,x_height],x_height+o+hair);
 numeric theta; theta=angle(z2-z1)+90;
 pos1(stem,theta); pos2(hair,theta);
 pos3(stem,theta); pos4(hair,theta);
 filldraw z1l---z2l--z2r---z1r..cycle;	% left diagonal
 filldraw z3l---z4l--z4r---z3r..cycle;	% right diagonal
else: pickup fine.nib; pos1(stem,0); pos2(vair,0);
 pos3(stem,0); pos4(vair,0);
 rt x3r=round(w-1.5u); lft x4l=round(.5w+u-.5vair);
 top y1=h; bot y2=round(2/3[h,x_height]);
 filldraw stroke z1e..z2e;	% left diagonal
 filldraw stroke z3e..z4e; fi	% right diagonal
penlabels(1,2,3,4); endchar;
cmchar "Tilde (squiggle) accent";
beginchar(oct"176",9u#,min(asc_height#,10/7x_height#+.5dot_size#),0);
italcorr h#*slant-u#;
adjust_fit(0,0);
if serifs: numeric theta; theta=angle(1/6(6u-vair),1/4(h-x_height));
 pickup crisp.nib; numeric mid_width; mid_width=round(.4[vair,stem]);
 pos1(vair,theta+90); pos2(vair,theta+90);
 pos3(vair,theta+90); pos4(vair,theta+90);
 z2-z1=z4-z3=(mid_width-crisp)*dir theta;
 lft x1r=w-rt x4l=round 1.5u; top y4r=h;
 bot y1l=round(bot y1l+min(2/3[x_height,h],y3l-.25vair)-top y1r);
 pair delta; ypart delta=3(y3l-y1l); delta=whatever*dir theta;
 filldraw z1l..controls(z1l+delta)and(z3l-delta)..z3l..z4l
  --z4r..controls(z4r-delta)and(z2r+delta)..z2r..z1r--cycle;	% stroke
else: pickup fine.nib; pos1(vair,180); pos2(vair,90);
 pos3(.5[vair,slab],90); pos4(vair,90); pos5(vair,180);
 lft x1r=w-rt x5l=round 1.5u; x2-x1=x3-x2=x4-x3=x5-x4;
 bot y1=bot y4l=round(.75[x_height,h]-vair); top y2r=top y5=h; y3=.5[y2,y4];
 filldraw stroke z1e{up}...z2e{right}..z3e..{right}z4e...{up}z5e; fi % stroke
penlabels(1,2,3,4,5); endchar;
cmchar "Umlaut (double dot) accent";
numeric dot_diam#,dot_diam;
dot_diam#=max(dot_size#,cap_curve#);
beginchar(oct"177",9u#,min(asc_height#,10/7x_height#+.5dot_diam#),0);
dot_diam=max(tiny.breadth,round(max(dot_size,cap_curve)-2stem_corr));
italcorr h#*slant+.5dot_diam#-2.25u#;
adjust_fit(0,0);
pickup tiny.nib; pos1(dot_diam,0); pos2(dot_diam,90);
x1=x2=2.75u; top y2r=h+1;
if bot y2l<x_height+o+slab: y2l:=min(y2r-2epsilon,x_height+o+slab+.5tiny); fi
y1=.5[y2l,y2r]; dot(1,2);	% left dot
pos3(dot_diam,0); penpos4(y2r-y2l,90); y3=y4=y1; x3=x4=w-x1;
dot(3,4);	% right dot
penlabels(1,2,3,4); endchar;